package com.intelligencesoft.pss.entity.base;

import java.util.Date;
import java.util.List;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import javax.persistence.Transient;

import org.hibernate.annotations.GenericGenerator;

import com.intelligencesoft.pss.entity.BasePojo;


@Entity
@Table(name="T_SYS_MENU")
public class SysMenu extends BasePojo{
	private static final long serialVersionUID = -683134370333048003L;
	
	private String menuId;
	private String icon;
	private String menuName;
	private String url;
	private String parentId;
	private List<SysMenu> menus;
	
	
	
	@Id
	@Column(name = "C_ID", nullable = false, length = 32)
	@GeneratedValue(generator = "system-uuid")
	@GenericGenerator(name = "system-uuid", strategy = "uuid")
	public String getId() {
		return super.getId();
	}
	
	public void setId(String id) {
		super.setId(id);
	}
	
	@Column(name="C_CREATE_DATE")
	@Temporal(value=TemporalType.TIMESTAMP)
	public Date getCreateDate() {
		return super.getCreateDate();
	}
	public void setCreateDate(Date createDate) {
		super.setCreateDate(createDate);
	}
	
	@Column(name="C_DESCRIPTION")
	public String getDescription() {
		return super.getDescription();
	}

	public void setDescription(String description) {
		super.setDescription(description);
	}
	
	@Column(name="C_MENU_ID")
	public String getMenuId() {
		return menuId;
	}
	public void setMenuId(String menuId) {
		this.menuId = menuId;
	}
	@Column(name="C_ICON")
	public String getIcon() {
		return icon;
	}
	public void setIcon(String icon) {
		this.icon = icon;
	}
	@Column(name="C_MENU_NAME")
	public String getMenuName() {
		return menuName;
	}
	public void setMenuName(String menuName) {
		this.menuName = menuName;
	}
	@Column(name="C_URL")
	public String getUrl() {
		return url;
	}
	public void setUrl(String url) {
		this.url = url;
	}
	@Column(name="C_PARENT_ID")
	public String getParentId() {
		return parentId;
	}
	public void setParentId(String parentId) {
		this.parentId = parentId;
	}
	
	@Transient
	public List<SysMenu> getMenus() {
		return menus;
	}

	public void setMenus(List<SysMenu> menus) {
		this.menus = menus;
	}
	
	
}
